import { createPinia } from "pinia";
// 引入Pinia和持久化插件 pinia-plugin-persistedstate
import piniaPluginPersistedstate from "pinia-plugin-persistedstate";

const store = createPinia();
store.use(piniaPluginPersistedstate);

/**
 * 注册全局 Store
 * @param app
 */
export function useSetupStore(app) {
  app.use(store);
}

export { store };
